#pragma once

#include "../Effects11/Inc/d3dx11effect.h"

namespace mgfx
{
	class HLSLEffect
	{
	public:
		static HLSLEffect * createFromFile(const std::string & fileName);
		static void freeAll();

		ID3DX11Effect * getEffect() { return mEffect; }

	private:
		HLSLEffect();
		~HLSLEffect();

		ID3DX11Effect * mEffect;

		typedef std::map<std::string, HLSLEffect*> ResourceMap;
		static ResourceMap mResources;
	};
}